package com.sicau.smart_farmer.repository;

import com.sicau.smart_farmer.entity.User;
import org.springframework.data.mongodb.repository.MongoRepository;

import java.util.List;

/**
 * @author sxt
 * @create 2019-11-22 16:40
 */
public interface UserRepository extends MongoRepository<User, String> {
    User findByWeChatNumIs(String weChatNum);

    User findUserById(String id);

    List<User> findUsersByNameLike(String name);

    List<User> findUsersByIdCardNumLike(String idCardNum);

    List<User> findUsersByNameLikeAndIdCardNumLike(String name,String idCardNum);

    List<User> findUsersByIdNotIn(List<String> ids);

    List<User> findUsersByIdentification(boolean isIdentified);





}
